﻿CREATE TABLE [dbo].[TopActiveUsers] (
    [WebApplicationID] UNIQUEIDENTIFIER NOT NULL,
    [Login]            NVARCHAR (200)   NOT NULL,
    [LastAccessTime]   DATETIME         NULL,
    [SuccessHitsRate]  FLOAT (53)       NULL,
    [Hits]             INT              NULL,
    CONSTRAINT [PK_TopActiveUsers] PRIMARY KEY CLUSTERED ([WebApplicationID] ASC, [Login] ASC),
    CONSTRAINT [FK_TopActiveUsers_WebApplication] FOREIGN KEY ([WebApplicationID]) REFERENCES [dbo].[WebApplication] ([WebApplicationID])
);

